<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <script src="../js/vue.js"></script>
    <title>Document</title>
</head>
<body>
    <div id="app">{{msg}}
        <!-- 拼接字符串 -->
        <p>{{msg + name1}}</p>
        <!-- 实现算数运算 -->
        <p>{{666+num1}}</p>
        <p>{{num1-num2}}</p>
        <p>{{111+222-333+4444}}</p>
        <!-- 添加三元表达式 -->
        <p>{{num1 > 666 ? name1 : name2}}</p>
        <!-- 调用api方法 -->
        <p>{{Math.round(num2)}}</p>
        <p>{{Math.random()}}</p>
        <!-- <p>{{alert(msg)}}</p> -->
        <!-- <p>{{parsrFloat(num2)}}</p> -->


    </div>
    
</body>
<script>
    var vm = new Vue({
        el : '#app',
        data : {
            msg : 'hello world',
            name1 : '佩奇',
            name2 : '乔治',
            name3 : '苏西',
            num1 : 666,
            num2 : 999.111,
            num3 : '1.23334dadas'
        }
    })
</script>
</html>